package com.cloud.util;

import com.supermap.desktop.core.utilties.PathUtilities;

import java.io.File;

public class FileUtil {
    /**
     * 获取geoJSON缓存路径
     *
     * @return 路径
     */
    public static String getGeoJSONCacheDir() {
        String path = PathUtilities.getDesktopPath() + "\\configuration\\GeoJSON";
        File file = new File(path);
        if (!file.exists()) {
            file.mkdir();
        }
        return path;
    }

    /**
     * 获取http缓存路径
     *
     * @return 路径
     */
    public static String getHttpCacheDir() {
        return PathUtilities.getDesktopPath() + "\\configuration\\cache\\http";
    }
}
